<%@page contentType="text/html;charset=UTF-8" language = "java"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt"%>
<html>
	<head>
		<title><c:out value="${item.title}"/> | JWiki</title>
		<link rel="stylesheet" href="texts/style.css" type="text/css" />
		<script type="text/javascript" src="texts/wiky.js"></script>
		<script type="text/javascript">
		/* <![CDATA[ */
		function load_funcs(){
		var text = document.getElementById('wiki-content').innerHTML;
		text = Wiky.toHtml(text);
		document.getElementById('wiki-content').innerHTML = text;
		};
		/* ]]> */
		</script>
	</head>
	<body onload=load_funcs()>
		<div id="page-wrapper">
			<c:import url="header.jsp"/>
			<c:import url="sidebar.jsp"/>
			<div id="content">
				<c:import url="navs.jsp"/>
				<c:if test="${item.type == 2}">
					<h2><c:out value="${item.title}"/></h2>
				</c:if>
				<c:if test="${item.type == 1}">
					<h2>目录：<c:out value="${item.title}"/></h2>
				</c:if>
				<c:if test="${item.type == 3}">
					<h2>文件：<c:out value="${item.title}"/></h2>
				</c:if>
				<c:if test="${item.type == 3}">
				<div class="img-item">
				 <c:if test="${fileType eq 'image'}">
				 <img width="600px" src="<c:out value="${fileBase}"/><c:out value="${item.title}"/>" alt="<c:out value="${item.title}"/>"/>
				 </c:if>
				 <c:if test="${fileType eq 'docs'}">
				 <img src="images/filetypes/6443.ico" alt="<c:out value="${item.title}"/>"/>
				 </c:if>
				  <c:if test="${fileType eq 'others'}">
				 <img src="images/filetypes/6438.ico" alt="<c:out value="${item.title}"/>"/>
				 </c:if>
				 <c:if test="${fileType eq 'media'}">
				 <img src="images/filetypes/6440.ico" alt="<c:out value="${item.title}"/>"/>
				 </c:if>
				 <c:if test="${fileType eq 'excel'}">
				 <img src="images/filetypes/6445.ico" alt="<c:out value="${item.title}"/>"/>
				 </c:if>
				 <c:if test="${fileType eq 'ppt'}">
				 <img src="images/filetypes/6446.ico" alt="<c:out value="${item.title}"/>"/>
				 </c:if>
				 <c:if test="${fileType eq 'pdf'}">
				 <img src="images/filetypes/6444.ico" alt="<c:out value="${item.title}"/>"/>
				 </c:if>
				 <c:if test="${fileType eq 'sound'}">
				 <img src="images/filetypes/6441.ico" alt="<c:out value="${item.title}"/>"/>
				 </c:if>
				 <br />
				 <a href="<c:out value="${fileBase}"/><c:out value="${item.title}"/>">点此下载</a>
				</div>
				</c:if>
				<div id="article" class="to-be-translate">
				<div id="wiki-content"><c:out value="${item.content}"/>
				</div>
				</div>
				<div id="item-metas">
					<span class="editor">Last Editor: <c:out value="${item.editor}"/></span>
					<span class="rev-id">Revision: <c:out value="${item.revId}"/></span>
					<span class="time">Time: <c:out value="${item.editTime}"/></span>
				</div>
			</div>
			<c:import url="footer.jsp"/>
		</div>
	</body>
</html>